package src;

import javax.swing.*;
import java.awt.*;
//import java.awt.*;

/**
 * Created by dell on 2017/8/1.
 */
public class FrameTest {
    public static void main(String[] args) {
        JFrame f=new JFrame("测试窗口");
        f.setLayout(new FlowLayout(FlowLayout.LEFT,20,5));
        for(int i=0;i<10;i++){
            f.add(new Button("按钮"+i));
        }
        //ScrollPane p=new ScrollPane(ScrollPane.SCROLLBARS_ALWAYS);
//        p.add(new TextField(20));
//        p.add(new Button("单击我"));
//        f.add(p);
        f.pack();
        //f.setBounds(30,30,250,120);
        f.setVisible(true);
    }
}
